package com.probox.common.core.enums;

public enum ServiceStatusEnum {
    //0取消售后,1申请待处理,2处理中,3拒绝售后,4同意售后,5买家已退货,商家待收货,6商家拒绝收货,待买家处理,7商家已发货,待买家收货,8售后成功
    cancel("0","取消售后"),
    apply("1","申请待处理"),
    processing("2","处理中"),
    refuse("3","拒绝售后"),
    agree("4","同意售后"),
//    returnReceive("5","买家已退货，商家待收货"),
//    refuseProcess("6","商家拒绝收货，待买家处理"),
//    sendReceive("7","商家已发货，待买家收货"),
    success("5","售后完成");

    private ServiceStatusEnum(String k, String v) {
        this.setKey(k);
        this.setValue(v);
    }

    public static String getNameByKey(String key) {
        String rst = "";
        for(ServiceStatusEnum oe: ServiceStatusEnum.values()) {
            if (oe.getKey().equals(key)) {
                rst = oe.getValue();
            }
        }
        return rst;
    }

    private String key;
    private String value;

    public String getKey() {
        return key;
    }
    public void setKey(String key) {
        this.key = key;
    }
    public String getValue() {
        return value;
    }
    public void setValue(String value) {
        this.value = value;
    }
}
